import request from '@/utils/request'

export default {

  // 上传图片
  uploadImg(data = {}) {
    return request({
      url: `/pri/file/upload/user`,
      method: 'post',
      data
    })
  },

  // 删除图片 /article/file/delete?fileUrl=http://xxxxx
  deleteImg(imageUrl) {
    return request({
      url: `/pri/file/delete`,
      method: 'delete',
      params: { 'fileUrl': imageUrl }
    })
  }

}
